import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart';
import 'package:moose_app/ui/values/constants.dart';

class ATHIconButton extends StatelessWidget {
  final String iconPath;

  final int width;

  final Color color;

  final Function press;

  ATHIconButton(
      {this.iconPath = 'assets/icons/icon_back.svg',
      this.color = Colors.white,
      this.width,
      this.press});

  @override
  Widget build(BuildContext context) {
    return IconButton(
      onPressed: null != press ? press : () {},
      icon: SvgPicture.asset(iconPath,
          color: color, width: width != null ? width : kSize48),
    );
  }
}
